
typedef struct MODULE_STRUCT
{
    unsigned _M_NEXT_HASH_GINDEX;	// NEXT MODULE THIS HASH, FOR PLINK, AND FOR DEBUGMODULES
    unsigned _M_NEXT_MODULE_GINDEX;
    unsigned _M_FIRST_PUB_GINDEX;	// FIRST PUBLIC SYMBOL THIS MODULE - FOR CV, DEFPUBS,
    unsigned _M_FILE_LIST_GINDEX;	// ACTUAL FILE_LIST ENTRY
    unsigned _M_MDB_GINDEX;		// PTR TO DEBUG STRUCTURE IF THERE IS ONE
    unsigned _M_LIBNUM;			// LIBRARY INDEX FOR THIS MODULE - I THINK JUST USED BY CODEVIEW...
#if fg_plink
    unsigned _M_SECTION_GINDEX;		// DEFINED SECTION
    unsigned char _M_PLTYPE;		// LEVEL 0?
    unsigned char _M_FLAGS;		// DEBUGGING THIS
#else
    unsigned char _M_FLAGS;		// DEBUGGING THIS
    unsigned char _M_DEBUG_FLAGS;	// FL_DEBUG_???
#endif
    unsigned short reserved;

    unsigned _M_TEXT;			// MODULE NAME

#if fg_td
    #define _M_TD_COMP_PARAMS	_M_LIBNUM
#endif
} MODULE_STRUCT;

#define M_SRCS_PRESENT	0x10

//M_FLAGS 	RECORD	M_PRECOMPILED_CV:1,M_OMIT_$$PUBLICS:1,M_SRCS_PRESENT:1,M_DEBUGGING_THIS:1,M_LOCALS:1,M_DEBUG_GLOBAL:1,M_USED:1

typedef struct MDB_STRUCT
{
    unsigned _MD_NEXT_MDB_GINDEX;		// NEXT MDB RECORD
    unsigned _MD_FIRST_SRC_GINDEX;		// FIRST SOURCE-FILE RECORD
    unsigned _MD_SRC_COUNT;			// NUMBER OF SOURCE FILES THIS MODULE

    unsigned _MD_FIRST_CSEGMOD_GINDEX;		// FIRST SEGMOD WITH CSEG RECORD THIS MODULE
    unsigned _MD_CSEG_COUNT;			// NUMBER OF CV CODE SEGMENTS

    unsigned _MD_CV_TYPES_GINDEX;		// CV SEGMOD IF NON-ZERO
    unsigned _MD_CV_SYMBOLS_GINDEX;		// CV SEGMOD IF NON-ZERO

    #define MDB_SIZE_CV		(7 * 4)		// SIZE OF STRUCTURE FOR CODEVIEW INFO

#if	fg_td

    unsigned _MD_TD_OPTFLAGS;		// OPTIMIZATION FLAGS PROVIDED FOR TD
    #define _MD_TD_LOCALS_INDEX32	(DWORD PTR _MD_CV_TYPES_GINDEX)	// INDEX OF FIRST LOCAL SYMBOL
    unsigned _MD_TD_LOCALS_COUNT;	// COUNT OF LOCAL SYMBOLS
    #define _MD_TD_CORR_INDEX	_MD_FIRST_CSEGMOD_GINDEX	// INDEX OF FIRST CORRELATION
    #define _MD_TD_CORR_COUNT	_MD_CSEG_COUNT			// COUNT OF CORRELATIONS
    unsigned _MD_TD_MOTHER_GINDEX;	// MODULE I BELONG TO
//  unsigned short _MD_TD_CLASS_INDEX;	// INDEX OF FIRST LOCAL CLASS
//  unsigned short _MD_TD_CLASS_COUNT;	// COUNT OF LOCAL CLASSES

#endif
} MDB_STRUCT;


typedef struct SRC_STRUCT		// SOURCE FILES MAINTAINED GLOBALLY, BUT HASHED LOCALLY
{
    unsigned _SRC_NEXT_HASH_GINDEX;	// NEXT SOURCE FILE SAME HASH
    unsigned _SRC_NEXT_GINDEX;
    unsigned _SRC_NUMBER;		// FOR COMPARING INDEXES... IN CVLIN4
#if fg_td
    unsigned _SRC_TND_STAMP;
#endif
    unsigned _SRC_HASH;
    unsigned _SRC_TEXT;
} SRC_STRUCT;

/*

_SRC_LINHELP_COUNT	EQU	_SRC_NEXT_HASH_GINDEX


CSEG_STRUCT	STRUC

_CSEG_NEXT_CSEGMOD_GINDEX	DD	?	;NEXT CODE SEGMOD THIS MODULE
_CSEG_PARENT_MOD_GINDEX		DD	?	;
_CSEG_FIRST_LINNUM		DD	?	;FIRST LINNUM RECORD THIS CSEG
_CSEG_LAST_LINNUM		DD	?	;LAST LINNUM_RECORD
if	fg_td
_CSEG_SCOPE_INDEX		DD	?	;FIRST SCOPE THIS SEGMOD
_CSEG_SCOPE_COUNT		DD	?	;# OF SCOPES THIS SEGMOD
_CSEG_COVERAGE_INDEX		DD	?	;FIRST COVERAGE
_CSEG_COVERAGE_COUNT		DD	?	;# OF COVERAGES

_CSEG_CORRELATION_INDEX		EQU	(_CSEG_FIRST_LINNUM.LW)
_CSEG_CORRELATION_COUNT		EQU	(_CSEG_FIRST_LINNUM.HW)
_CSEG_TD_SEG_INDEX		EQU	(_CSEG_LAST_LINNUM.LW)
_CSEG_TD_MOD_INDEX		EQU	(_CSEG_LAST_LINNUM.HW)
_CSEG_FIRST_COVERAGE		EQU	(DWORD PTR _CSEG_COVERAGE_INDEX)
endif

CSEG_STRUCT	ENDS

.LIST

*/
